from scipy.optimize import minimize

# Define a function to minimize
def f(x):
    return x**2 + 10*np.sin(x)

# Find the minimum
result = minimize(f, x0=0)
print("Minimum value:", result.x)